package com.example.demo.model;

import javax.validation.constraints.Max;
import javax.validation.constraints.NotNull;

import com.example.demo.validation.DtoValidator;

/**
* @comments
* @author  zg
* @date 2018年8月28日 
*/
public class Person extends DtoValidator<Person>{
	private static final long serialVersionUID = 1L;

	@NotNull(message = "姓名不能为空")
	private String name;
	
	//@NotNull(message = "年龄不能为空")
	@Max(value = 100, message = "年龄不能超过100岁")
	private Integer age;
	
	private String gender;

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Integer getAge() {
		return age;
	}

	public void setAge(Integer age) {
		this.age = age;
	}

	public String getGender() {
		return gender;
	}

	public void setGender(String gender) {
		this.gender = gender;
	}
	
	
}
